# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.DFAReporting.V34.Model.AdSlot do
  @moduledoc """
  Ad Slot

  ## Attributes

  *   `comment` (*type:* `String.t`, *default:* `nil`) - Comment for this ad slot.
  *   `compatibility` (*type:* `String.t`, *default:* `nil`) - Ad slot compatibility. DISPLAY and DISPLAY_INTERSTITIAL refer to rendering either on desktop, mobile devices or in mobile apps for regular or interstitial ads respectively. APP and APP_INTERSTITIAL are for rendering in mobile apps. IN_STREAM_VIDEO refers to rendering in in-stream video ads developed with the VAST standard.
  *   `height` (*type:* `String.t`, *default:* `nil`) - Height of this ad slot.
  *   `linkedPlacementId` (*type:* `String.t`, *default:* `nil`) - ID of the placement from an external platform that is linked to this ad slot.
  *   `name` (*type:* `String.t`, *default:* `nil`) - Name of this ad slot.
  *   `paymentSourceType` (*type:* `String.t`, *default:* `nil`) - Payment source type of this ad slot.
  *   `primary` (*type:* `boolean()`, *default:* `nil`) - Primary ad slot of a roadblock inventory item.
  *   `width` (*type:* `String.t`, *default:* `nil`) - Width of this ad slot.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :comment => String.t() | nil,
          :compatibility => String.t() | nil,
          :height => String.t() | nil,
          :linkedPlacementId => String.t() | nil,
          :name => String.t() | nil,
          :paymentSourceType => String.t() | nil,
          :primary => boolean() | nil,
          :width => String.t() | nil
        }

  field(:comment)
  field(:compatibility)
  field(:height)
  field(:linkedPlacementId)
  field(:name)
  field(:paymentSourceType)
  field(:primary)
  field(:width)
end

defimpl Poison.Decoder, for: GoogleApi.DFAReporting.V34.Model.AdSlot do
  def decode(value, options) do
    GoogleApi.DFAReporting.V34.Model.AdSlot.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.DFAReporting.V34.Model.AdSlot do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
